//
//  ScoreAndExchange.m
//  NiuBanJin
//
//  Created by Billy on 15/10/16.
//  Copyright © 2015年 zzjr. All rights reserved.
//

#import "ScoreAndExchange.h"

@implementation ScoreAndExchange

-(instancetype)initWithDictionary:(NSDictionary *)dic {
    
   self = [super init];
    if (self) {
    
        if (![dic isKindOfClass:[NSNull class]]) {
            
            self.scoreAndExchange_reason = dic[@"prodName"];
            self.scoreAndExchange_value = dic[@"score"];
            self.scoreAndExchange_time = dic[@"exchangDate"];
            self.scoreAndExchange_isConsume = [NSNumber numberWithBool:YES];
        }
    }
    return self;
}

-(instancetype)initScoreListWithDictionary:(NSDictionary *)dic  {
    
    if (self = [super init]) {
        
        self.scoreAndExchange_reason = [dic objectForKey:@"reason"];
        self.scoreAndExchange_time = [dic objectForKey:@"date"];
        self.scoreAndExchange_Scorevalue = [dic objectForKey:@"scores"];
    }
    
    return self;
}

@end
